package com.team1.supervend.domain;

public class AccountingSystem {
	private static IAccountingAdapter accountingAdapter;
	AccountingSystem(){
		initialize();
	}

	void initialize()
	{
		System.out.println("    ");
		System.out.println("Singleton AccountingSystemFactory and accountingAdapter ready for service:");
		System.out.println("    ");
		// create the singleton AccountingSystemFactory via the static getInstance method and 
		// create the accountingAdapter using the getAccountingAdapter method
		accountingAdapter = AccountingSystemFactory.getInstance().getAccountingAdapter();
	}

	IAccountingAdapter getAccountingAdapter()
	{
		return accountingAdapter;
	}
	
}
